package com.cpecc.model.wuzi;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.hibernate.annotations.GenericGenerator;

import com.cpecc.model.system.User;

@Entity
@Table(name = "DATA_CAIGOU_USER")
public class CaiGouSPR implements Serializable{
	
	/**
	 * 
	 */
	private static final long serialVersionUID = 1251374475787840380L;

	@Id
	@GeneratedValue(generator = "system-uuid")
	@GenericGenerator(name = "system-uuid", strategy = "uuid")
	@Column(length = 32)
	private String id;
	
	@ManyToOne
	@JoinColumn(name="SHENQING_ID")
	private ShenQing shenQing;
	
	@ManyToOne
	@JoinColumn(name="USER_ID")
	private User user;
	
	@Column
	private int no;

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public ShenQing getShenQing() {
		return shenQing;
	}

	public void setShenQing(ShenQing shenQing) {
		this.shenQing = shenQing;
	}

	public User getUser() {
		return user;
	}

	public void setUser(User user) {
		this.user = user;
	}

	public int getNo() {
		return no;
	}

	public void setNo(int no) {
		this.no = no;
	}

	public CaiGouSPR(String id, ShenQing shenQing, User user, int no) {
		super();
		this.id = id;
		this.shenQing = shenQing;
		this.user = user;
		this.no = no;
	}

	public CaiGouSPR() {
		super();
	}	
}
